//Graphic for DirectX game

#ifndef DXGAMEGRAPHIC_H
#define DXGAMEGRAPHIC_H

#include <d3dx9.h>
#include "game.h"

using namespace game;

class DXGameGraphic : public GameGraphic
{	
  public:
    DXGameGraphic();
    //Constructor (HandleWindow, WidthScreen, HeightScreen, FullScreen)
    DXGameGraphic(HWND, int, int, bool = false);
    virtual bool Init();
    virtual void* GetDevice();
    virtual int GetWidthScreen();
    virtual int GetHeightScreen();
    virtual bool BeginRender();
    virtual bool EndRender();
    virtual bool IsFullScreen();
    virtual ~DXGameGraphic();

  private:
    HWND hWnd;						//Handle window
    IDirect3D9* pD3D;				//Pointer to interface DirectX graphic
    IDirect3DDevice9* pD3DDevice;	//Pointer to interface DirectX graphic device
    D3DPRESENT_PARAMETERS d3dpp;	//Parameter to init device graphic
    int widthScreen;				//Width of screen
    int heightScreen;				//Height of screen
    bool fullScreen;				//Check and change mode of screen (window or fullscreen)
};

#endif